#include "rc4wrapper.h"

void RC4Wrapper::Enc(const void* in, size_t inlen, const void* key, size_t keylen, std::__cxx11::string& outstr)
{
    RC4_KEY rc4key;
    outstr.resize(inlen);
    char *data = const_cast<char *> (outstr.data());
    RC4_set_key(&rc4key, keylen, (const unsigned char*)key);
    RC4(&rc4key, inlen, (const unsigned char*)in, (unsigned char *)data);
}

